home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-04 / 422mods.zip / TFC003.422 < prev    next >
Text File  |  1993-03-01  |  12KB  |  331 lines

  1. 2TFC003.MOD 1The Complete Clear Screen Mod
  2. The Flying Chicken [SysOp] #1 @12456
  3. 3Saturday, February 27, 1993  1 8:09 pm
  4.  
  5. TFC003.MOD - The Complete Clear Screen Mod
  6. Author: The Flying Chicken 1@12456 (WWIVLink) 1@2456 (WWIVNet) 1@2456 (IceNet)
  7. Source: WWIV 4.20 thru 4.22
  8. Version: 1.1
  9.  
  10.     I know that there are about four hundred versions of this mod,
  11.     but none of them were complete in my eyes, so I've decided
  12.     to release the one I use.  This mod will allow you to clear
  13.     the screen before reading each message or e-mail, and also
  14.     before writing messages or e-mail.  Also, an option will be
  15.     added to the defaults section so you can toggle this option
  16.     on and off.  And finally, newusers will be asked if the
  17.     want the clear screen feature.
  18.  
  19.     One final note, Wayne evidentally was planning on using
  20.     this feature since there is a variable set up for it, but it
  21.     isn't used yet, so we will just save Wayne some work.
  22.  
  23.  
  24.     For WWIV 4.22, look for the version number of v1.1!  A 4.22 note,
  25.     this mod replaces some of the get_string() calls with actual
  26.     strings.  This is done for simple reasons, it's easier that way.
  27.     If you want to modify your string thru ESM instead of replacing
  28.     the function call, feel free.  I don't include those instructions,
  29.     since not everyone uses ESM, but if you know anything about ESM,
  30.     it isn't hard.
  31.  
  32.     v1.1    Upgrade to 4.22
  33.     v1.0    Initial version
  34.  
  35.  
  36.     Before using this or any mod, back up your source !!!!!
  37.  
  38.                 PKZIP source *.c *.h *.mak
  39.  
  40.  
  41.     1. Load up MSGBASE.C and search for void read_message() and
  42.        make the following changes.
  43.  
  44. void read_message(int n, int *next, int *val)
  45. {
  46.   char s[100],s1[80];
  47.   postrec p;
  48.   int abort,a;
  49.   slrec ss;
  50.  
  51.   nl();                                             /* DELETE THIS LINE */
  52.   abort=0;
  53.   *next=0;
  54.   if (thisuser.sysstatus & sysstatus_clr_scrn)      /* ADD */
  55.     outchr(12);                                     /* ADD */
  56.   else                                              /* ADD */
  57.     nl();                                           /* ADD */
  58.   sprintf(s,"(%u/%u): ",n,nummsgs);
  59.   osan(s,&abort,next);
  60.   ansic(MSG_COLOR);
  61.   p=msgs[n];
  62.  
  63.  
  64.     2. Search for void inmsg(), scroll down some, and make
  65.        the changes shown.
  66.  
  67.        v1.1 - Note that 4.22 code is slightly different in this
  68.               area, look for the WWIV version numbers below!
  69.  
  70.   nl();
  71.   helpl=6;
  72.   if ((thisuser.sysstatus & sysstatus_clr_scrn) && (!fsed))     /* ADD */
  73.     outchr(12);                                                 /* ADD */
  74.   if (okansi()) {
  75.     prt(2,"Title: ");                       /* WWIV 4.21a and under ONLY */
  76.     prt(2,get_string(326));                 /* WWIV 4.22 ONLY */
  77.     mpl(60);
  78.     inputl(title,60);
  79.   } else {
  80.     pl("       (---=----=----=----=----=----=----=----=----=----=----=----)");
  81.     outstr("Title: ");
  82.     inputl(title,60);
  83.   }
  84.  
  85.     3. Save MSGBASE.C.
  86.     4. Load MSGBASE1.C.  Search for void readmail().  Scroll down
  87.        a little farther, and make the following changes.
  88.  
  89.     i=atoi(s);
  90.     if (i)
  91.       if (i<=mw)
  92.         curmail=i-1;
  93.       else
  94.         curmail=0;
  95.     else
  96.       curmail=0;
  97.   }
  98.   done=0;
  99.   do {
  100.     if (thisuser.sysstatus & sysstatus_clr_scrn)        /* ADD */
  101.         outchr(12);                                     /* ADD */
  102.     else {                                              /* ADD */
  103.         nl();nl();                                      /* ADD */
  104.     }                                                   /* ADD */
  105.     sprintf(s,"(%u/%u): ",curmail+1,mw);
  106.     abort=0;
  107.     nl();                                           /* DELETE THIS LINE */
  108.     nl();                                           /* DELETE THIS LINE */
  109.     osan(s,&abort,&next);
  110.     next=0;
  111.     ansic(MSG_COLOR);
  112.  
  113.  
  114.     5. Save MSGBASE1.C.
  115.     6. Load DEFAULTS.C.  Search for print_cur_stat() and make the
  116.        following changes.
  117.  
  118.        v1.1 - This block is split into two parts, one for WWIV versions
  119.               up to 4.21a, the second part for WWIV 4.22 ONLY.  If you
  120.               have 4.21a or under, do this part.  If you have 4.22, go
  121.               to the block following this one.
  122.  
  123.     /* v1.1 - This block is for 4.21a and under ONLY */
  124.  
  125.     npr("A. Extended colors   : %s\r\n",
  126.       (thisuser.sysstatus & sysstatus_funky_colors)?"Yes":"No");
  127.   }
  128.   npr("B. Optional lines    : %d\r\n",thisuser.optional_val);
  129.   npr("C. Clear screen      : %s\r\n",                              /* ADD */
  130.     (thisuser.sysstatus & sysstatus_clr_scrn)?"Yes":"No");          /* ADD */
  131.   if (thisuser.wwiv_regnum)
  132.     npr("W. WWIV reg num      : %ld\r\n",thisuser.wwiv_regnum);
  133.   else
  134.     pl("W. WWIV reg num      : <NONE>");
  135.   pl("Q. Quit to main menu");
  136.  
  137.  
  138.     /* v1.1 - This block is for 4.22 ONLY */
  139.  
  140.     outstr(get_string(399)); npr("%s\r\n",
  141.       (thisuser.sysstatus & sysstatus_funky_colors)?str_yes:str_no);
  142.   }
  143.   outstr(get_string(400)); npr("%d\r\n",thisuser.optional_val);
  144.   npr("C. Clear Screen      : %s\r\n",                                /* ADD */
  145.     (thisuser.sysstatus & sysstatus_clr_scrn) ? "Yes" : "No");        /* ADD */
  146.   outstr(get_string(401));
  147.   if (thisuser.wwiv_regnum)
  148.     npr("%ld\r\n",thisuser.wwiv_regnum);
  149.   else
  150.     pl(get_string(402));
  151.   pl(get_string(403));
  152.  
  153.  
  154.     7. Search for void defaults() and make the following changes.
  155.  
  156. void defaults()
  157. {
  158.   int i,i1,i2,done;
  159.   char s[81],s1[81],s2[81],ch;
  160.  
  161.   done=0;
  162.   print_cur_stat();
  163.   do {
  164.     nl();
  165.     helpl=4;
  166.     if (okansi()) {
  167.       prt(2,"Defaults: (1-9,A-C,?,Q) : ");          /* CHANGE */
  168.       ch=onek("Q?123456789ABCW");                   /* CHANGE */
  169.     } else {
  170.       prt(2,"Defaults: (1-7,C,?,Q) : ");            /* CHANGE */
  171.       ch=onek("Q?1234567BCW");                      /* CHANGE */
  172.     }
  173.  
  174.  
  175.     8.  Scroll down a little farther and make the changes.
  176.  
  177.       case 'B':
  178.         optional_lines();
  179.         break;
  180.       case 'C':                                             /* ADD */
  181.         if (thisuser.sysstatus & sysstatus_clr_scrn)        /* ADD */
  182.             thisuser.sysstatus ^= sysstatus_clr_scrn;       /* ADD */
  183.         nl();                                               /* ADD */
  184.         prt(5,"Clear screen before each message? ");        /* ADD */
  185.         if (yn())                                           /* ADD */
  186.             thisuser.sysstatus |= sysstatus_clr_scrn;       /* ADD */
  187.         break;                                              /* ADD */
  188.       case 'W':
  189.         enter_regnum();
  190.         break;
  191.  
  192.  
  193.     9. Save DEFAULTS.C.
  194.     10. Load NEWUSER.C.  Search for void newuser() and add the following
  195.         function right before it.
  196.  
  197. void input_clr_scrn()                       /* ADD ENTIRE VOID */
  198. {
  199.     if (thisuser.sysstatus & sysstatus_clr_scrn)
  200.         thisuser.sysstatus ^= sysstatus_clr_scrn;
  201.     nl();
  202.     prt(5,"Clear screen before each message? ");
  203.     if (yn())
  204.         thisuser.sysstatus |= sysstatus_clr_scrn;
  205.  
  206. }
  207.  
  208.  
  209.     11. Now search for void newuser(), scroll down a few pages,
  210.         and make the changes shown.
  211.  
  212.     input_sex();
  213.     input_age(&thisuser);
  214.     input_comptype();
  215.     input_screensize();
  216.     input_clr_scrn();                                   /* ADD */
  217.     nl();
  218.     npr("Random password: %s\r\n",thisuser.pw);
  219.     nl();
  220.  
  221.  
  222.     12.  Scroll down farther, and continue with the changes.
  223.  
  224.     v1.1 - Here again, the next block is for 4.21a and under only!  If
  225.            you are running 4.22, go to the block after this one and
  226.            continue!
  227.  
  228.     /* for 4.21a and under only */
  229.  
  230.       npr("5. Gender        : %c\r\n",thisuser.sex);
  231.       npr("6. Birthdate     : %02d/%02d/%02d\r\n",
  232.         (int) thisuser.month, (int) thisuser.day, (int) thisuser.year);
  233.       npr("7. Computer type : %s\r\n",ctypes[thisuser.comp_type]);
  234.       npr("8. Screen size   : %d X %d\r\n",
  235.         thisuser.screenchars, thisuser.screenlines);
  236.       decode_pw(t,thisuser.pw);
  237.       npr("9. Password      : %s\r\n",t);
  238.       npr("A. Clear Screen  : %s\r\n",                              /* ADD */
  239.         (thisuser.sysstatus & sysstatus_clr_scrn)?"Yes":"No");      /* ADD */
  240.       pl("Q. No changes.");
  241.       nl();
  242.       nl();
  243.       prt(2,"Which (1-A,Q) : ");                       /* CHANGE */
  244.       ch=onek("Q123456789A");                          /* CHANGE */
  245.       ok=0;
  246.  
  247.  
  248.     /* for 4.22 only */
  249.  
  250.       if (syscfg.sysconfig & sysconfig_extended_info) {
  251.         outstr(get_string(582)); pl(thisuser.street);
  252.         outstr(get_string(583)); pl(thisuser.city);
  253.         outstr(get_string(584)); pl(thisuser.state);
  254.         outstr(get_string(585)); pl(thisuser.country);
  255.         outstr(get_string(586)); pl(thisuser.zipcode);
  256.         outstr(get_string(587)); pl(thisuser.dataphone);
  257.       }
  258.       npr("S. Clear Screen  : %s\r\n",                           /* ADD */
  259.         (thisuser.sysstatus & sysstatus_clr_scrn)?"Yes":"No");   /* ADD */
  260.       nl();
  261.       pl(get_string(588));
  262.       nl();
  263.       nl();
  264.       if (syscfg.sysconfig & sysconfig_extended_info) {
  265.         prt(2,"Which (1-9,A-F,S,Q) : ");                /* CHANGE */
  266.         ch=onek("Q123456789ABCDEFS");                   /* CHANGE */
  267.       } else {
  268.         prt(2,"Which (1-9,S,Q) : ");                    /* CHANGE */
  269.         ch=onek("Q123456789S");                         /* CHANGE */
  270.       }
  271.       ok=0;
  272.  
  273.  
  274.     13. And still further down...  One last change.
  275.  
  276.         case '5': input_sex(); break;
  277.         case '6': input_age(&thisuser); break;
  278.         case '7': input_comptype(); break;
  279.         case '8': input_screensize(); break;
  280.         case '9': input_pw(); break;
  281.         case 'A': input_clr_scrn();break;         /* 4.21 AND UNDER ADD */
  282.         case 'S': input_clr_scrn();break;         /* 4.22 ONLY ADD */
  283.       }
  284.  
  285.  
  286.     DISCLAIMER:  I make no guarantees with this mod whatsoever.
  287.     Your installation of the mod is your acceptance of any
  288.     damages caused to your hardware or software, incendental or
  289.     otherwise.
  290.  
  291.     The mod was tested with the versions of WWIV mentioned in
  292.     this file. If the mod does NOT work for you, e-mail one of
  293.     the addresses above, and tell me EXACTLY what you did, what
  294.     the screen said, and what you did to try to fix it, and I'll
  295.     do what I can to help you out.
  296.  
  297.     PLEASE REPORT ANY BUGS TO ME AT THE ABOVE ADDRESS !!!!!!!
  298.     Any other comments, suggestions, hints, things I missed,
  299.     requests for new mods, and general "Thank you!"s are all VERY
  300.     welcomed, so drop me a line.  I don't mind updates to this
  301.     mod, but do request that you send me a courtesy copy of the
  302.     changes you made.
  303.  
  304.     *****************************************************************
  305.                               Subscribe to:
  306.  
  307.                     Modding with WWIV's Flying Chicken
  308.  
  309.               WWIVLink subtype 42456, Host @12456 (REQable)
  310.                WWIVNet subtype 42456, Host @2456 (REQable)
  311.                 IceNet subtype 42456, Host @2456 (REQable)
  312.  
  313.        All mods are released on this sub first.  Occasionally, they
  314.        make the mods subs, but usually much later.  Subscribe now!
  315.     *****************************************************************
  316.  
  317.                            The Flying Chicken
  318.        1@12456 (WWIVLink)  -  1@2456 (WWIVNet) - 1@2456 (IceNet)
  319.  
  320.                          THE INSANE ASYLUM BBS
  321.                     In Operation Since August, 1989
  322.  
  323.                    Running WWIV 4.22++  (Reg #21260)
  324.           SysOp: The Flying Chicken  -  CoSysOp: Dr. Doolittle
  325.                   Snarfable  -  Auto-SysOp Validation
  326.                  Callback Validation (Local calls only)
  327.                (214) 570-5950  -  USR Dual Std (v32/HST)
  328.  
  329.                           --- END OF LINE ---
  330.  
  331.